// 需要鉴权的业务路由
import { RouteRecordRaw } from 'vue-router';
import Layout from '@/layout/index.vue';

const asyncRoutes: Array<RouteRecordRaw> = [
  {
    path: '/front-end-stage',
    component: Layout,
    redirect: '/css',
    meta: { title: '首页', icon: '' },
    children: [
      {
        path: '/index',
        meta: { title: '原生', icon: '' },
        name: 'Index',
        children: [
          {
            path: '/css',
            meta: {title: '悬停视差', icon: ''},
            name: 'Css',
            component: () => import('@/views/Css/ParallaxHovering/index.vue')
          },
          {
            path: '/gradient',
            meta: {title: '渐变', icon: ''},
            name: 'Gradient',
            component: () => import('@/views/Css/Gradient/index.vue')
          },
          {
            path: '/xxxx',
            meta: {title: 'xxxx页面', icon: ''},
            name: 'Xxxx',
            component: () => import('@/views/Css/xxxx/index.vue')
          },
        ]
      },
      {
        path: '/canvas',
        name: 'Canvas',
        meta: { title: 'Canvas', icon: '' },
        component: () => import('@/views/Css/xxxx/index.vue'),
      },
      {
        path: '/echarts',
        name: 'Echarts',
        meta: { title: 'Echarts', icon: '' },
        component: () => import('@/views/Css/xxxx/index.vue'),
      },
      {
        path: '/three',
        name: 'Three',
        meta: { title: 'Three', icon: '' },
        component: () => import('@/views/Css/xxxx/index.vue'),
      },
      {
        path: '/fabric',
        name: 'FabricJS',
        meta: { title: 'FabricJS', icon: '' },
        children: [
          {
            path: '/fabricStart',
            meta: {title: '起步', icon: ''},
            name: 'FabricStart',
            children: [
              {
                path: '/fabric-rect',
                meta: {title: '矩形', icon: ''},
                name: 'FabricRect',
                component: () => import('@/views/Fabric/start/rect.vue')
              },
              {
                path: '/fabric-circle',
                meta: {title: '圆形', icon: ''},
                name: 'FabricCircle',
                component: () => import('@/views/Fabric/start/circle.vue')
              },
              {
                path: '/fabric-ellipse',
                meta: {title: '椭圆', icon: ''},
                name: 'FabricEllipse',
                component: () => import('@/views/Fabric/start/ellipse.vue')
              },
              {
                path: '/fabric-triangle',
                meta: {title: '三角形', icon: ''},
                name: 'FabricTriangle',
                component: () => import('@/views/Fabric/start/triangle.vue')
              },
              {
                path: '/fabric-polygon',
                meta: {title: '多边形', icon: ''},
                name: 'FabricPolygon',
                component: () => import('@/views/Fabric/start/polygon.vue')
              },
              {
                path: '/fabric-line',
                meta: {title: '线段', icon: ''},
                name: 'FabricLine',
                component: () => import('@/views/Fabric/start/line.vue')
              },
              {
                path: '/fabric-text',
                meta: {title: '文本', icon: ''},
                name: 'FabricText',
                component: () => import('@/views/Fabric/start/text.vue')
              },
              {
                path: '/fabric-itext',
                meta: {title: '可编辑文本', icon: ''},
                name: 'FabricItext',
                component: () => import('@/views/Fabric/start/itext.vue')
              },
              {
                path: '/fabric-textbox',
                meta: {title: '文本框', icon: ''},
                name: 'FabricTextbox',
                component: () => import('@/views/Fabric/start/textbox.vue')
              },
            ]
          },
        ]
      },
    ],
  },
  // {
  //   path: '/I18nGenerator',
  //   component: Layout,
  //   children: [
  //     {
  //       path: '/common-tools/I18nGenerator',
  //       name: 'I18nGenerator',
  //       component: () => import('@/views/I18nGenerator/index.vue'),
  //     },
  //   ],
  // },
  // {
  //   path: '/common-tools/process',
  //   name: 'process',
  //   meta: {
  //     title: 'Template configuration process',
  //     icon: '',
  //   },
  //   component: () => import('@/views/example/MarkdownPage.vue'),
  // },
];

export default asyncRoutes;
